<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Documento sin título</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.2/themes/smoothness/jquery-ui.css" />
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.2/jquery-ui.min.js"></script>


</head>

<body>

<table width="100%" border="1">
  <tr>
    <td>
<!----------------------------------------------------------------------------------------------------------INICIO 1 -->        
<table width="100%" border="1">
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>

<!----------------------------------------------------------------------------------------------------------FIN 1 -->            
    </td>
  </tr>
  <tr>
    <td>
    
<!----------------------------------------------------------------------------------------------------------INICIO 2 -->    
<table width="100%" border="1">
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>
<!----------------------------------------------------------------------------------------------------------FIN 2 -->    
    
    
    </td>
  </tr>
  <tr>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>
<!----------------------------------------------------------------------------------------------------------INICIO 3 -->        

<br>

<script>
$(document).ready(function(e) {
    eliminar_fila();
});
</script>
<script>

//		nueva_fila  = '<tr>';
//		nueva_fila  += '    <td>xxxxxxxx</td>';
//		nueva_fila  += '    <td>&nbsp;</td>';
//		nueva_fila  += '    <td>&nbsp;</td>';
//		nueva_fila  += '    <td>&nbsp;</td>';
//		nueva_fila  += '    <td>&nbsp;</td>';
//		nueva_fila  += '</tr>';		


	var contador_nueva_fila = 2;
	function displayResult()
	{	
		var nueva_fila = '';	

		
		nueva_fila  = '  <tr>';
		nueva_fila  += '    <td align="right" >';
		nueva_fila  += '    <strong class="eliminar" >&nbsp;</strong>';
		nueva_fila  += '    dsadsadsa';
		nueva_fila  += '    </td>  ';
		nueva_fila  += '    <td align="right" class="numeracion">ssssssss</td>';
		nueva_fila  += '    <td align="right" ><input name="nombre" type="text" value="nombre" /></td>';
		nueva_fila  += '  </tr>';
  
  		
		
		document.getElementById("Tabla_nueva_fila").insertRow(-1).innerHTML = nueva_fila;
		contador_nueva_fila++;
	}

	function eliminar_fila(){
	$(function(){
		$(document).on("click",".eliminar",function(){
		if(contador_nueva_fila>2){
			var parent = $(this).parents().parents().get(0);
			$(parent).remove();
			contador_nueva_fila--;
			$(".numeracion").each(function (index) {
				$(this).text(index + 1);
			});			
		}
		});
	
	});
	}
</script>

<style>
.addFila:hover{
	background-image: url('../imagenes/listABC/add.png');
	background-repeat: no-repeat;
}

.eliminar:hover{
	background-image: url('../imagenes/listABC/close.png');
	background-repeat: no-repeat;
}

.eliminar{
/*	background-image: url('../imagenes/listABC/close.png');
	background-repeat: no-repeat;*/
	float:left;
	min-width:15px;
/*	border-width: 0;*/
}


</style>
    
<!----------------------------------------------------------------------------------------------------------FIN 3 -->            

<table id="Tabla_nueva_fila" width="100%" border="1" style="background-color:#CCFFFF">
  <tr>
    <td colspan="3">
        <strong class="addFila" onClick="displayResult()" >&nbsp;&nbsp;&nbsp;&nbsp;</strong>
        Observaciones
    </td>
  </tr>
  
  
  <tr>
    <td align="right" >
    <strong class="eliminar" >&nbsp;</strong>
    dsadsadsa
    </td>  
    <td align="right" class="numeracion">ssssssss</td>
    <td align="right" ><input name="nombre" type="text" value="nombre" /></td>
  </tr>
  
  
</table>


<br>
    </td>
  </tr>
  <tr>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
  </tr>
</table>



</body>
</html>





